#!/bin/bash

if [[ $# < 2 ]]; then
	echo "parameters are not enough"
	echo "./batch_run.sh graph_dir graph_type
	exit
fi

inputdir=$1
type=$2

if [[ ! -d $inputdir ]]; then
	echo $inputdir " is not exist"
	exit
fi

for file in `ls $inputdir|grep $type`;
do
	file=$inputdir/$file
	echo ./perf_branch.sh ./run.sh bfs $file
	./perf_branch.sh ./run.sh bfs $file
	echo ./perf_branch.sh ./run.sh cc $file
	./perf_branch.sh ./run.sh cc $file
	echo ./perf_branch.sh ./run.sh tc $file
	./perf_branch.sh ./run.sh tc $file
	echo ./perf_branch.sh ./run.sh pr $file
	./perf_branch.sh ./run.sh pr $file
done


